package com.e3.web.widget.client;

import com.extjs.gxt.ui.client.widget.form.Radio;

public class MyRadio<X> extends Radio implements MyField<X>{
	
	private X valueObject;
	
	private boolean isHide = false;

	@SuppressWarnings("unchecked")
	public X getFieldValue() {
		if(valueObject == null){
			valueObject=(X)getValue();
		}
		return valueObject;
	}

	@SuppressWarnings("unchecked")
	public void setFieldValue(Object valueObject) {
		this.valueObject = (X)valueObject;
	}
	
	@Override
	public void hide() {
		isHide = true;
		super.hide();
	}

	public boolean isHide() {
		return isHide;
	}
}
